// https://github.com/dreambo8563/next-vue-storage-watcher
import { createWatcher } from 'next-vue-storage-watcher'
const prefixIdx = 'pg'
export const ls = createWatcher({
  prefix: `${prefixIdx}_ls_`
})
export const ss = createWatcher({
  prefix: `${prefixIdx}_ss_`,
  storage: 'session'
})
export function setupStorage(app) {
  app.use(ls)
  app.use(ss)
}

/**
  import { useLSWatcher } from "next-vue-storage-watcher";
  import { useSSWatcher } from "next-vue-storage-watcher";

  ls.setItem('aaa', 444444)
  ls.getItem('aaa').value
  ls.removeItem('aaa')
  ls.clear()
*/
